package com.example.spring5demo;

public class SynchronizedDemo1 {

    public synchronized void test1(){}

    public  void test2(){
        synchronized (this){}
    }

}
